package com.rockcent.mall.lib.domain;

import com.rockcent.common.domain.IDEntityMall;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.io.Serializable;

/**
 * Created by zhangjh on 2016/9/23.
 */
@Entity
@Table(name = "customer_bank")
@DynamicInsert(value = true)
@DynamicUpdate(value = true)
public class CustomerBank extends IDEntityMall {


    /**
     * 银行卡号
     */
    @Column(columnDefinition = "varchar(255) comment '银行卡号'")
    private String bankCard;


    /**
     * 银行类型
     */
    @Column(columnDefinition = "bigint comment '银行卡类型'")
    private Long bankTypeId;


    /**
     * 持卡人
     */
    @Column(columnDefinition = "varchar(255) comment '持卡人'")
    private String cardHolder;

    /**
     * 客户ID
     */
    @Column(columnDefinition = "bigint comment '客户ID'")
    private Long customerId;

    @Column(columnDefinition = "bigint comment'用户手机号'")
    private Long phone;

    public Long getPhone() {
        return phone;
    }

    public void setPhone(Long phone) {
        this.phone = phone;
    }

    public String getBankCard() {
        return bankCard;
    }

    public void setBankCard(String bankCard) {
        this.bankCard = bankCard;
    }

    public Long getBankTypeId() {
        return bankTypeId;
    }

    public void setBankTypeId(Long bankTypeId) {
        this.bankTypeId = bankTypeId;
    }

    public String getCardHolder() {
        return cardHolder;
    }

    public void setCardHolder(String cardHolder) {
        this.cardHolder = cardHolder;
    }

    public Long getCustomerId() {
        return customerId;
    }

    public void setCustomerId(Long customerId) {
        this.customerId = customerId;
    }


    @Override
    public String toString() {
        return "CustomerBank{" +
                "bankCard='" + bankCard + '\'' +
                ", id=" + id +
                ", bankTypeId=" + bankTypeId +
                ", dateCreated=" + dateCreated +
                ", cardHolder='" + cardHolder + '\'' +
                ", lastUpdated=" + lastUpdated +
                ", customerId=" + customerId +
                ", isDelete=" + isDelete +
                ", phone=" + phone +
                ", version=" + version +
                '}';
    }
}
